<!DOCTYPE html>
<html>

<head>
    <title>{$theme_vars.plate_name|default=''} {$site_info.site_name|default=''}</title>
    <meta name="keywords" content="{$site_info.site_seo_keywords|default=''}" />
    <meta name="description" content="{$site_info.site_seo_description|default=''}">
    <include file="public@head" />
    <link href="__TMPL__/public/assets/css/slippry/slippry.css" rel="stylesheet">
    <style>
        .caption-wraper {
            position: absolute;
            left: 50%;
            bottom: 2em;
        }

        .caption .caption-wraper a img {
            height: 56.875vw;
        }

        .caption-wraper .caption {
            display: none;
        }
    </style>
    <widgetsHead />
    <hook name="before_head_end" />
</head>
<php>
    $exInfo = json_encode($theme_vars['exhibitionInfo'], true);
</php>
<body class="body-white">
    <include file="public@nav" />
    <div>
        <div id="pageHeader">
            <img src="http://{$theme_vars.https}/upload/{$theme_vars.upImg}" alt="">
        </div>
        <div id="pageContent">
            <div id="newsTitle">
                <div id="title">
                    关于展会
                </div>
                <div class="text" 
                    v-for="(item,index) in infoList" 
                    :key="index"
                    @click="check(item,index+1)"
                    :class="current ==index+1  ?'current' : ''"
                >
                    {{item.title}}
                </div>
                
            </div>
            <div class="pageInfo">
                <div>
                    {{exInfo.content}}
                </div>
                <div>
                    <img style="width:39.063vw" :src="`http://{$theme_vars.https}/upload/`+ exInfo.image" alt="">
                </div>
            </div>
        </div>
    </div>
    <include file="public@footer" />
    <!-- /container -->
    <include file="public@scripts" />
    <widgetsScript />
    <hook name="before_body_end" />
</body>

</html>
<script>
    const app = new Vue({
        el: '#pageContent',
        data() {
            return{
                infoList:[],
                current:1,
                exInfo:{},
            }
        },
        created(){
            this.infoList = JSON.parse('{$exInfo}') 
            this.exInfo = this.infoList[0]
            let str =location.search;
            let search =str.substr(1);
            console.log(str,search)
            if(search){
                this.current = search
                this.exInfo = this.infoList[this.current-1]
            }
        },
        methods:{
            check(e,num){
                this.exInfo = e
                this.current = num
            }
        }
    })
   
</script>
<style>
    

    #pageHeader {
        background-color: #ccc;
       display: flex;
       justify-content: center;
    }

    #pageHeader img {
        width: 100vw;
        height: 17.188vw;
        
    }

    #pageContent {
        display: flex;
        width: 62.5vw;
        margin: 2.604vw auto;
    }
    #pageContent #newsTitle{
        display: flex;
        flex-direction: column;
    }
    #pageContent #newsTitle #title{
        height: 2.604vw;
        width: 14.583vw;
        padding-left: 2.604vw;
        font-size: 1.146vw;
        color: #333;
        background-color: #f2f2f2;
        margin-bottom: 1.042vw;
        line-height: 2.604vw;
        font-weight: 600;
    }
    #pageContent #newsTitle .text{
        width: 13.021vw;
        font-size: 1.042vw;
        color: #333;
        padding: 0.521vw 0 0.521vw 49.997px;
        cursor: pointer;
        margin: 0.521vw 0;
    }
    #pageContent #newsTitle .text:hover{
       background-color: #FF913C;
       color: #FFF;
    }
    #pageContent #newsTitle .current{
        background-color: #FF913C;
        color: #FFF;
    }
    #pageContent .pageForm{
        flex: 1;
        border-style: solid;
        border-width: 0.052vw 0.052vw 0.052vw 0.052vw;
        border-color: #48B4E0;
        box-shadow: 0vw 0vw 0.26vw 0vw rgba(0,0,0,0.5);
        transition: background 0.3s, border 0.3s, border-radius 0.3s, box-shadow 0.3s;
        padding: 1.563vw 2.604vw 1.563vw 2.604vw;
    }
    #pageContent  .pageInfo{
        flex: 1;
        display: flex;
        flex-direction: column;
        justify-content: center;
        align-content: flex-start;
        margin-left: 1.563vw;
    }
    #pageContent  .pageInfo p{
        color: #333;
        font-size: 0.833vw;
        font-weight:600 ;
        font-family: "Raleway", Microsoft Yahei;
        margin: 0.521vw 0 0 0;
    }
 
</style>